home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1998 January: Mac OS SDK / Dev.CD Jan 98 SDK1.toast / Development Kits (Disc 1) / Interfaces&Libraries / Universal / Interfaces / AIncludes / NetSprocket.a < prev    next >
Encoding:
Text File  |  1997-08-12  |  18.0 KB  |  603 lines  |  [TEXT/MPS ]

  1. ;
  2. ;    File:        NetSprocket.a
  3. ;
  4. ;    Contains:    Games Sprockets: NetSprocket interfaces
  5. ;
  6. ;    Version:    Technology:    NetSprocket 1.0.2
  7. ;                Release:    Universal Interfaces 3.0.1
  8. ;
  9. ;    Copyright:    © 1996-1997 by Apple Computer, Inc., all rights reserved.
  10. ;
  11. ;    Bugs?:        Please include the the file and version information (from above) with
  12. ;                the problem description.  Developers belonging to one of the Apple
  13. ;                developer programs can submit bug reports to:
  14. ;
  15. ;                    devsupport@apple.com
  16. ;
  17. ;
  18.     IF &TYPE('__NETSPROCKET__') = 'UNDEFINED' THEN
  19. __NETSPROCKET__ SET 1
  20.  
  21.     IF &TYPE('__TYPES__') = 'UNDEFINED' THEN
  22.     include 'Types.a'
  23.     ENDIF
  24.     IF &TYPE('__EVENTS__') = 'UNDEFINED' THEN
  25.     include 'Events.a'
  26.     ENDIF
  27.  
  28. kNSpMaxPlayerNameLen            EQU        31
  29. kNSpMaxGroupNameLen                EQU        31
  30. kNSpMaxPasswordLen                EQU        31
  31. kNSpMaxGameNameLen                EQU        31
  32. kNSpMaxDefinitionStringLen        EQU        255
  33.  
  34. ;  NetSprocket basic types 
  35.  
  36.  
  37.  
  38.  
  39.  
  40.  
  41.  
  42.  
  43. ; typedef SInt32                         NSpEventCode
  44.  
  45. ; typedef SInt32                         NSpGameID
  46.  
  47. ; typedef SInt32                         NSpPlayerID
  48.  
  49. ; typedef NSpPlayerID                     NSpGroupID
  50.  
  51. ; typedef UInt32                         NSpPlayerType
  52.  
  53. ; typedef SInt32                         NSpFlags
  54.  
  55. ;  Individual player info 
  56. NSpPlayerInfo            RECORD 0
  57. id                         ds.l    1                ; offset: $0 (0)
  58. playerType                 ds.l    1                ; offset: $4 (4)        ;  was type
  59. name                     ds        Str31            ; offset: $8 (8)
  60. groupCount                 ds.l    1                ; offset: $28 (40)
  61. groups                     ds.l    1                ; offset: $2C (44) <-- really an array of length one
  62. sizeof                     EQU *                    ; size:   $30 (48)
  63.                         ENDR
  64. ; typedef struct NSpPlayerInfo *        NSpPlayerInfoPtr
  65.  
  66. ;  list of all players 
  67. NSpPlayerEnumeration    RECORD 0
  68. count                     ds.l    1                ; offset: $0 (0)
  69. playerInfo                 ds.l    1                ; offset: $4 (4) <-- really an array of length one
  70. sizeof                     EQU *                    ; size:   $8 (8)
  71.                         ENDR
  72. ; typedef struct NSpPlayerEnumeration *    NSpPlayerEnumerationPtr
  73.  
  74. ;  Individual group info 
  75. NSpGroupInfo            RECORD 0
  76. id                         ds.l    1                ; offset: $0 (0)
  77. playerCount                 ds.l    1                ; offset: $4 (4)
  78. players                     ds.l    1                ; offset: $8 (8) <-- really an array of length one
  79. sizeof                     EQU *                    ; size:   $C (12)
  80.                         ENDR
  81. ; typedef struct NSpGroupInfo *            NSpGroupInfoPtr
  82.  
  83. ;  List of all groups 
  84. NSpGroupEnumeration        RECORD 0
  85. count                     ds.l    1                ; offset: $0 (0)
  86. groups                     ds.l    1                ; offset: $4 (4) <-- really an array of length one
  87. sizeof                     EQU *                    ; size:   $8 (8)
  88.                         ENDR
  89. ; typedef struct NSpGroupEnumeration *    NSpGroupEnumerationPtr
  90.  
  91. ;  Topology types 
  92. ; typedef UInt32                         NSpTopology
  93.  
  94.  
  95. kNSpClientServer                EQU        $00000001
  96. ;  Game information 
  97. NSpGameInfo                RECORD 0
  98. maxPlayers                 ds.l    1                ; offset: $0 (0)
  99. currentPlayers             ds.l    1                ; offset: $4 (4)
  100. currentGroups             ds.l    1                ; offset: $8 (8)
  101. topology                 ds.l    1                ; offset: $C (12)
  102. reserved                 ds.l    1                ; offset: $10 (16)
  103. name                     ds        Str31            ; offset: $14 (20)
  104. password                 ds        Str31            ; offset: $34 (52)
  105. sizeof                     EQU *                    ; size:   $54 (84)
  106.                         ENDR
  107. ;  Structure used for sending and receiving network messages 
  108. NSpMessageHeader        RECORD 0
  109. version                     ds.l    1                ; offset: $0 (0)        ;  Used by NetSprocket.  Don't touch this 
  110. what                     ds.l    1                ; offset: $4 (4)        ;  The kind of message (e.g. player joined) 
  111. from                     ds.l    1                ; offset: $8 (8)        ;  ID of the sender 
  112. toID                     ds.l    1                ; offset: $C (12)        ;  (player or group) id of the intended recipient (was "to) 
  113. id                         ds.l    1                ; offset: $10 (16)        ;  Unique ID for this message & (from) player 
  114. when                     ds.l    1                ; offset: $14 (20)        ;  Timestamp for the message 
  115. messageLen                 ds.l    1                ; offset: $18 (24)        ;  Bytes of data in the entire message (including the header) 
  116. sizeof                     EQU *                    ; size:   $1C (28)
  117.                         ENDR
  118. ;  NetSprocket-defined message structures 
  119. NSpErrorMessage            RECORD 0
  120. header                     ds        NSpMessageHeader ; offset: $0 (0)
  121. error                     ds.l    1                ; offset: $1C (28)
  122. sizeof                     EQU *                    ; size:   $20 (32)
  123.                         ENDR
  124. NSpJoinRequestMessage    RECORD 0
  125. header                     ds        NSpMessageHeader ; offset: $0 (0)
  126. name                     ds        Str31            ; offset: $1C (28)
  127. password                 ds        Str31            ; offset: $3C (60)
  128. theType                     ds.l    1                ; offset: $5C (92)
  129. customDataLen             ds.l    1                ; offset: $60 (96)
  130. customData                 ds.b    1                ; offset: $64 (100) <-- really an array of length one
  131.                          ORG 102
  132. sizeof                     EQU *                    ; size:   $66 (102)
  133.                         ENDR
  134. NSpJoinApprovedMessage    RECORD 0
  135. header                     ds        NSpMessageHeader ; offset: $0 (0)
  136. sizeof                     EQU *                    ; size:   $1C (28)
  137.                         ENDR
  138. NSpJoinDeniedMessage    RECORD 0
  139. header                     ds        NSpMessageHeader ; offset: $0 (0)
  140. reason                     ds        Str255            ; offset: $1C (28)
  141. sizeof                     EQU *                    ; size:   $11C (284)
  142.                         ENDR
  143. NSpPlayerJoinedMessage    RECORD 0
  144. header                     ds        NSpMessageHeader ; offset: $0 (0)
  145. playerCount                 ds.l    1                ; offset: $1C (28)
  146. playerInfo                 ds        NSpPlayerInfo    ; offset: $20 (32)
  147. sizeof                     EQU *                    ; size:   $50 (80)
  148.                         ENDR
  149. NSpPlayerLeftMessage    RECORD 0
  150. header                     ds        NSpMessageHeader ; offset: $0 (0)
  151. playerCount                 ds.l    1                ; offset: $1C (28)
  152. playerID                 ds.l    1                ; offset: $20 (32)
  153. sizeof                     EQU *                    ; size:   $24 (36)
  154.                         ENDR
  155. NSpHostChangedMessage    RECORD 0
  156. header                     ds        NSpMessageHeader ; offset: $0 (0)
  157. newHost                     ds.l    1                ; offset: $1C (28)
  158. sizeof                     EQU *                    ; size:   $20 (32)
  159.                         ENDR
  160. NSpGameTerminatedMessage RECORD 0
  161. header                     ds        NSpMessageHeader ; offset: $0 (0)
  162. sizeof                     EQU *                    ; size:   $1C (28)
  163.                         ENDR
  164. ;  Different kinds of messages.  These can NOT be bitwise ORed together 
  165.  
  166. kNSpSendFlag_Junk                EQU        $00100000            ; will be sent (try once) when there is nothing else pending 
  167. kNSpSendFlag_Normal                EQU        $00200000            ; will be sent immediately (try once) 
  168. kNSpSendFlag_Registered            EQU        $00400000            ; will be sent immediately (guaranteed, in order) 
  169.  
  170. ;  Options for message delivery.  These can be bitwise ORed together with each other,
  171. ;        as well as with ONE of the above 
  172.  
  173. kNSpSendFlag_FailIfPipeFull        EQU        $00000001
  174. kNSpSendFlag_SelfSend            EQU        $00000002
  175. kNSpSendFlag_Blocking            EQU        $00000004
  176.  
  177. ;  Options for Hosting Joining, and Deleting games 
  178.  
  179. kNSpGameFlag_DontAdvertise        EQU        $00000001
  180. kNSpGameFlag_ForceTerminateGame    EQU        $00000002
  181. ;  Message "what" types 
  182. ;  Apple reserves all negative "what" values (anything with bit 32 set) 
  183.  
  184. kNSpSystemMessagePrefix            EQU        $80000000
  185. kNSpError                        EQU        $FFFFFFFF
  186. kNSpJoinRequest                    EQU        $80000001
  187. kNSpJoinApproved                EQU        $80000002
  188. kNSpJoinDenied                    EQU        $80000003
  189. kNSpPlayerJoined                EQU        $80000004
  190. kNSpPlayerLeft                    EQU        $80000005
  191. kNSpHostChanged                    EQU        $80000006
  192. kNSpGameTerminated                EQU        $80000007
  193.  
  194. ;  Special TPlayerIDs  for sending messages 
  195.  
  196. kNSpAllPlayers                    EQU        $00000000
  197. kNSpHostOnly                    EQU        $FFFFFFFF
  198.  
  199. ;  NetSprocket Error Codes 
  200.  
  201. kNSpInitializationFailedErr        EQU        -30360
  202. kNSpAlreadyInitializedErr        EQU        -30361
  203. kNSpTopologyNotSupportedErr        EQU        -30362
  204. kNSpPipeFullErr                    EQU        -30364
  205. kNSpHostFailedErr                EQU        -30365
  206. kNSpProtocolNotAvailableErr        EQU        -30366
  207. kNSpInvalidGameRefErr            EQU        -30367
  208. kNSpInvalidParameterErr            EQU        -30369
  209. kNSpOTNotPresentErr                EQU        -30370
  210. kNSpOTVersionTooOldErr            EQU        -30371
  211. kNSpMemAllocationErr            EQU        -30373
  212. kNSpAlreadyAdvertisingErr        EQU        -30374
  213. kNSpNotAdvertisingErr            EQU        -30376
  214. kNSpInvalidAddressErr            EQU        -30377
  215. kNSpFreeQExhaustedErr            EQU        -30378
  216. kNSpRemovePlayerFailedErr        EQU        -30379
  217. kNSpAddressInUseErr                EQU        -30380
  218. kNSpFeatureNotImplementedErr    EQU        -30381
  219. kNSpNameRequiredErr                EQU        -30382
  220. kNSpInvalidPlayerIDErr            EQU        -30383
  221. kNSpInvalidGroupIDErr            EQU        -30384
  222. kNSpNoPlayersErr                EQU        -30385
  223. kNSpNoGroupsErr                    EQU        -30386
  224. kNSpNoHostVolunteersErr            EQU        -30387
  225. kNSpCreateGroupFailedErr        EQU        -30388
  226. kNSpAddPlayerFailedErr            EQU        -30389
  227. kNSpInvalidDefinitionErr        EQU        -30390
  228. kNSpInvalidProtocolRefErr        EQU        -30391
  229. kNSpInvalidProtocolListErr        EQU        -30392
  230. kNSpTimeoutErr                    EQU        -30393
  231. kNSpGameTerminatedErr            EQU        -30394
  232. kNSpConnectFailedErr            EQU        -30395
  233. kNSpSendFailedErr                EQU        -30396
  234. kNSpJoinFailedErr                EQU        -30399
  235.  
  236.  
  237.  
  238. ; ************************  Initialization  ***********************
  239. ;
  240. ; extern OSStatus NSpInitialize(UInt32 inStandardMessageSize, UInt32 inBufferSize, UInt32 inQElements, NSpGameID inGameID, UInt32 inTimeout)
  241. ;
  242.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  243.         IMPORT_CFM_FUNCTION NSpInitialize
  244.     ENDIF
  245.  
  246.  
  247.  
  248.  
  249. ; **************************  Protocols  *************************
  250. ;  Programmatic protocol routines 
  251. ;
  252. ; extern OSStatus NSpProtocol_New(const char *inDefinitionString, NSpProtocolReference *outReference)
  253. ;
  254.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  255.         IMPORT_CFM_FUNCTION NSpProtocol_New
  256.     ENDIF
  257.  
  258. ;
  259. ; extern void NSpProtocol_Dispose(NSpProtocolReference inProtocolRef)
  260. ;
  261.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  262.         IMPORT_CFM_FUNCTION NSpProtocol_Dispose
  263.     ENDIF
  264.  
  265. ;
  266. ; extern OSStatus NSpProtocol_ExtractDefinitionString(NSpProtocolReference inProtocolRef, char *outDefinitionString)
  267. ;
  268.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  269.         IMPORT_CFM_FUNCTION NSpProtocol_ExtractDefinitionString
  270.     ENDIF
  271.  
  272.  
  273. ;  Protocol list routines 
  274. ;
  275. ; extern OSStatus NSpProtocolList_New(NSpProtocolReference inProtocolRef, NSpProtocolListReference *outList)
  276. ;
  277.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  278.         IMPORT_CFM_FUNCTION NSpProtocolList_New
  279.     ENDIF
  280.  
  281. ;
  282. ; extern void NSpProtocolList_Dispose(NSpProtocolListReference inProtocolList)
  283. ;
  284.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  285.         IMPORT_CFM_FUNCTION NSpProtocolList_Dispose
  286.     ENDIF
  287.  
  288. ;
  289. ; extern OSStatus NSpProtocolList_Append(NSpProtocolListReference inProtocolList, NSpProtocolReference inProtocolRef)
  290. ;
  291.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  292.         IMPORT_CFM_FUNCTION NSpProtocolList_Append
  293.     ENDIF
  294.  
  295. ;
  296. ; extern OSStatus NSpProtocolList_Remove(NSpProtocolListReference inProtocolList, NSpProtocolReference inProtocolRef)
  297. ;
  298.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  299.         IMPORT_CFM_FUNCTION NSpProtocolList_Remove
  300.     ENDIF
  301.  
  302. ;
  303. ; extern OSStatus NSpProtocolList_RemoveIndexed(NSpProtocolListReference inProtocolList, UInt32 inIndex)
  304. ;
  305.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  306.         IMPORT_CFM_FUNCTION NSpProtocolList_RemoveIndexed
  307.     ENDIF
  308.  
  309. ;
  310. ; extern UInt32 NSpProtocolList_GetCount(NSpProtocolListReference inProtocolList)
  311. ;
  312.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  313.         IMPORT_CFM_FUNCTION NSpProtocolList_GetCount
  314.     ENDIF
  315.  
  316. ;
  317. ; extern NSpProtocolReference NSpProtocolList_GetIndexedRef(NSpProtocolListReference inProtocolList, UInt32 inIndex)
  318. ;
  319.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  320.         IMPORT_CFM_FUNCTION NSpProtocolList_GetIndexedRef
  321.     ENDIF
  322.  
  323.  
  324. ;  Helpers 
  325. ;
  326. ; extern NSpProtocolReference NSpProtocol_CreateAppleTalk(ConstStr31Param inNBPName, ConstStr31Param inNBPType, UInt32 inMaxRTT, UInt32 inMinThruput)
  327. ;
  328.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  329.         IMPORT_CFM_FUNCTION NSpProtocol_CreateAppleTalk
  330.     ENDIF
  331.  
  332. ;
  333. ; extern NSpProtocolReference NSpProtocol_CreateIP(InetPort inPort, UInt32 inMaxRTT, UInt32 inMinThruput)
  334. ;
  335.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  336.         IMPORT_CFM_FUNCTION NSpProtocol_CreateIP
  337.     ENDIF
  338.  
  339.  
  340. ; ***********************  Human Interface  ***********************
  341. ;
  342. ; extern NSpAddressReference NSpDoModalJoinDialog(ConstStr31Param inGameType, ConstStr255Param inEntityListLabel, Str31 ioName, Str31 ioPassword, NSpEventProcPtr inEventProcPtr)
  343. ;
  344.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  345.         IMPORT_CFM_FUNCTION NSpDoModalJoinDialog
  346.     ENDIF
  347.  
  348. ;
  349. ; extern Boolean NSpDoModalHostDialog(NSpProtocolListReference ioProtocolList, Str31 ioGameName, Str31 ioPlayerName, Str31 ioPassword, NSpEventProcPtr inEventProcPtr)
  350. ;
  351.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  352.         IMPORT_CFM_FUNCTION NSpDoModalHostDialog
  353.     ENDIF
  354.  
  355.  
  356. ; *********************  Hosting and Joining  *********************
  357. ;
  358. ; extern OSStatus NSpGame_Host(NSpGameReference *outGame, NSpProtocolListReference inProtocolList, UInt32 inMaxPlayers, ConstStr31Param inGameName, ConstStr31Param inPassword, ConstStr31Param inPlayerName, NSpPlayerType inPlayerType, NSpTopology inTopology, NSpFlags inFlags)
  359. ;
  360.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  361.         IMPORT_CFM_FUNCTION NSpGame_Host
  362.     ENDIF
  363.  
  364. ;
  365. ; extern OSStatus NSpGame_Join(NSpGameReference *outGame, NSpAddressReference inAddress, ConstStr31Param inName, ConstStr31Param inPassword, NSpPlayerType inType, void *inCustomData, UInt32 inCustomDataLen, NSpFlags inFlags)
  366. ;
  367.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  368.         IMPORT_CFM_FUNCTION NSpGame_Join
  369.     ENDIF
  370.  
  371. ;
  372. ; extern OSStatus NSpGame_EnableAdvertising(NSpGameReference inGame, NSpProtocolReference inProtocol, Boolean inEnable)
  373. ;
  374.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  375.         IMPORT_CFM_FUNCTION NSpGame_EnableAdvertising
  376.     ENDIF
  377.  
  378. ;
  379. ; extern OSStatus NSpGame_Dispose(NSpGameReference inGame, NSpFlags inFlags)
  380. ;
  381.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  382.         IMPORT_CFM_FUNCTION NSpGame_Dispose
  383.     ENDIF
  384.  
  385. ;
  386. ; extern OSStatus NSpGame_GetInfo(NSpGameReference inGame, NSpGameInfo *ioInfo)
  387. ;
  388.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  389.         IMPORT_CFM_FUNCTION NSpGame_GetInfo
  390.     ENDIF
  391.  
  392. ; **************************  Messaging  *************************
  393. ;
  394. ; extern OSStatus NSpMessage_Send(NSpGameReference inGame, NSpMessageHeader *inMessage, NSpFlags inFlags)
  395. ;
  396.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  397.         IMPORT_CFM_FUNCTION NSpMessage_Send
  398.     ENDIF
  399.  
  400. ;
  401. ; extern NSpMessageHeader *NSpMessage_Get(NSpGameReference inGame)
  402. ;
  403.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  404.         IMPORT_CFM_FUNCTION NSpMessage_Get
  405.     ENDIF
  406.  
  407. ;
  408. ; extern void NSpMessage_Release(NSpGameReference inGame, NSpMessageHeader *inMessage)
  409. ;
  410.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  411.         IMPORT_CFM_FUNCTION NSpMessage_Release
  412.     ENDIF
  413.  
  414. ;  Helpers 
  415. ;
  416. ; extern OSStatus NSpMessage_SendTo(NSpGameReference inGame, NSpPlayerID inTo, SInt32 inWhat, void *inData, UInt32 inDataLen, NSpFlags inFlags)
  417. ;
  418.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  419.         IMPORT_CFM_FUNCTION NSpMessage_SendTo
  420.     ENDIF
  421.  
  422.  
  423. ; *********************  Player Information  *********************
  424. ;
  425. ; extern NSpPlayerID NSpPlayer_GetMyID(NSpGameReference inGame)
  426. ;
  427.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  428.         IMPORT_CFM_FUNCTION NSpPlayer_GetMyID
  429.     ENDIF
  430.  
  431. ;
  432. ; extern OSStatus NSpPlayer_GetInfo(NSpGameReference inGame, NSpPlayerID inPlayerID, NSpPlayerInfoPtr *outInfo)
  433. ;
  434.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  435.         IMPORT_CFM_FUNCTION NSpPlayer_GetInfo
  436.     ENDIF
  437.  
  438. ;
  439. ; extern void NSpPlayer_ReleaseInfo(NSpGameReference inGame, NSpPlayerInfoPtr inInfo)
  440. ;
  441.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  442.         IMPORT_CFM_FUNCTION NSpPlayer_ReleaseInfo
  443.     ENDIF
  444.  
  445. ;
  446. ; extern OSStatus NSpPlayer_GetEnumeration(NSpGameReference inGame, NSpPlayerEnumerationPtr *outPlayers)
  447. ;
  448.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  449.         IMPORT_CFM_FUNCTION NSpPlayer_GetEnumeration
  450.     ENDIF
  451.  
  452. ;
  453. ; extern void NSpPlayer_ReleaseEnumeration(NSpGameReference inGame, NSpPlayerEnumerationPtr inPlayers)
  454. ;
  455.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  456.         IMPORT_CFM_FUNCTION NSpPlayer_ReleaseEnumeration
  457.     ENDIF
  458.  
  459. ;
  460. ; extern UInt32 NSpPlayer_GetRoundTripTime(NSpGameReference inGame, NSpPlayerID inPlayer)
  461. ;
  462.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  463.         IMPORT_CFM_FUNCTION NSpPlayer_GetRoundTripTime
  464.     ENDIF
  465.  
  466. ;
  467. ; extern UInt32 NSpPlayer_GetThruput(NSpGameReference inGame, NSpPlayerID inPlayer)
  468. ;
  469.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  470.         IMPORT_CFM_FUNCTION NSpPlayer_GetThruput
  471.     ENDIF
  472.  
  473.  
  474. ; *********************  Group Management  *********************
  475. ;
  476. ; extern OSStatus NSpGroup_New(NSpGameReference inGame, NSpGroupID *outGroupID)
  477. ;
  478.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  479.         IMPORT_CFM_FUNCTION NSpGroup_New
  480.     ENDIF
  481.  
  482. ;
  483. ; extern OSStatus NSpGroup_Dispose(NSpGameReference inGame, NSpGroupID inGroupID)
  484. ;
  485.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  486.         IMPORT_CFM_FUNCTION NSpGroup_Dispose
  487.     ENDIF
  488.  
  489. ;
  490. ; extern OSStatus NSpGroup_AddPlayer(NSpGameReference inGame, NSpGroupID inGroupID, NSpPlayerID inPlayerID)
  491. ;
  492.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  493.         IMPORT_CFM_FUNCTION NSpGroup_AddPlayer
  494.     ENDIF
  495.  
  496. ;
  497. ; extern OSStatus NSpGroup_RemovePlayer(NSpGameReference inGame, NSpGroupID inGroupID, NSpPlayerID inPlayerID)
  498. ;
  499.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  500.         IMPORT_CFM_FUNCTION NSpGroup_RemovePlayer
  501.     ENDIF
  502.  
  503. ;
  504. ; extern OSStatus NSpGroup_GetInfo(NSpGameReference inGame, NSpGroupID inGroupID, NSpGroupInfoPtr *outInfo)
  505. ;
  506.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  507.         IMPORT_CFM_FUNCTION NSpGroup_GetInfo
  508.     ENDIF
  509.  
  510. ;
  511. ; extern void NSpGroup_ReleaseInfo(NSpGameReference inGame, NSpGroupInfoPtr inInfo)
  512. ;
  513.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  514.         IMPORT_CFM_FUNCTION NSpGroup_ReleaseInfo
  515.     ENDIF
  516.  
  517. ;
  518. ; extern OSStatus NSpGroup_GetEnumeration(NSpGameReference inGame, NSpGroupEnumerationPtr *outGroups)
  519. ;
  520.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  521.         IMPORT_CFM_FUNCTION NSpGroup_GetEnumeration
  522.     ENDIF
  523.  
  524. ;
  525. ; extern void NSpGroup_ReleaseEnumeration(NSpGameReference inGame, NSpGroupEnumerationPtr inGroups)
  526. ;
  527.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  528.         IMPORT_CFM_FUNCTION NSpGroup_ReleaseEnumeration
  529.     ENDIF
  530.  
  531.  
  532. ; **************************  Utilities  **************************
  533. ;
  534. ; extern NumVersion NSpGetVersion(void )
  535. ;
  536.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  537.         IMPORT_CFM_FUNCTION NSpGetVersion
  538.     ENDIF
  539.  
  540. ;
  541. ; extern void NSpClearMessageHeader(NSpMessageHeader *inMessage)
  542. ;
  543.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  544.         IMPORT_CFM_FUNCTION NSpClearMessageHeader
  545.     ENDIF
  546.  
  547. ;
  548. ; extern UInt32 NSpGetCurrentTimeStamp(NSpGameReference inGame)
  549. ;
  550.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  551.         IMPORT_CFM_FUNCTION NSpGetCurrentTimeStamp
  552.     ENDIF
  553.  
  554. ;
  555. ; extern NSpAddressReference NSpConvertOTAddrToAddressReference(OTAddress *inAddress)
  556. ;
  557.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  558.         IMPORT_CFM_FUNCTION NSpConvertOTAddrToAddressReference
  559.     ENDIF
  560.  
  561. ;
  562. ; extern OTAddress *NSpConvertAddressReferenceToOTAddr(NSpAddressReference inAddress)
  563. ;
  564.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  565.         IMPORT_CFM_FUNCTION NSpConvertAddressReferenceToOTAddr
  566.     ENDIF
  567.  
  568. ;
  569. ; extern void NSpReleaseAddressReference(NSpAddressReference inAddress)
  570. ;
  571.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  572.         IMPORT_CFM_FUNCTION NSpReleaseAddressReference
  573.     ENDIF
  574.  
  575.  
  576. ; ************************ Advanced/Async routines ***************
  577. ;
  578. ; extern OSStatus NSpInstallCallbackHandler(NSpCallbackProcPtr inHandler, void *inContext)
  579. ;
  580.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  581.         IMPORT_CFM_FUNCTION NSpInstallCallbackHandler
  582.     ENDIF
  583.  
  584.  
  585. ;
  586. ; extern OSStatus NSpInstallJoinRequestHandler(NSpJoinRequestHandlerProcPtr inHandler, void *inContext)
  587. ;
  588.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  589.         IMPORT_CFM_FUNCTION NSpInstallJoinRequestHandler
  590.     ENDIF
  591.  
  592.  
  593. ;
  594. ; extern OSStatus NSpInstallAsyncMessageHandler(NSpMessageHandlerProcPtr inHandler, void *inContext)
  595. ;
  596.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  597.         IMPORT_CFM_FUNCTION NSpInstallAsyncMessageHandler
  598.     ENDIF
  599.  
  600.  
  601.     ENDIF ; __NETSPROCKET__ 
  602.  
  603.